import React, { Component } from 'react'

export default class Progress extends Component {
	constructor(props) {
		super(props);

		this.state = {};
	}

	render() {
		return(
			<div className={"w-progress " + this.props.style}>
				<div className="w-progress-line">
					<span></span>
					<span></span>
					<span></span>
				</div>
				{this.props.titles.map((title, i) =>
					<div key={i} className="w-progress-step">{title}</div>
				)}
			</div>
		)
		
	}
}

Progress.defaultProps = {
	titles: ["支付订单", "处理订单", "订单完成"],
	style: "success-50" //success-50、success-100、fail-50、fail-100
}